#include "CProduction_Scope.h"

CTokenPtr CProduction_Scope_Begin_exec_link::Reduce( CProductionArgPtr pArgs )
{
	GET_GRAMMAR()->enterScope()->setExecute(true);


	return CTokenFactory::createToken<CToken>();
}

CTokenPtr CProduction_Scope_End_exec_link::Reduce( CProductionArgPtr pArgs )
{
	GET_GRAMMAR()->leaveScope();


	return CTokenFactory::createToken<CToken>();
}

CTokenPtr CProduction_Scope_Begin_noexec_link::Reduce( CProductionArgPtr pArgs )
{
	GET_GRAMMAR()->enterScope()->setExecute(false);


	return CTokenFactory::createToken<CToken>();
}

CTokenPtr CProduction_Scope_End_noexec_link::Reduce( CProductionArgPtr pArgs )
{
	GET_GRAMMAR()->leaveScope();


	return CTokenFactory::createToken<CToken>();
}